package com.example.workone;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

public class UC4 extends AppCompatActivity {

    private Button bn1;
    private Button bn2;
    private Button bn3;
    private Button bn4;
    private Button bnReturn;


    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_uc4);

        bn1 = findViewById(R.id.btn1);
        bn2 = findViewById(R.id.btn2);
        bn3 = findViewById(R.id.btn3);
        bn4 = findViewById(R.id.btn4);
        bnReturn = findViewById(R.id.btn5);

        bn1.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //跳转到UC1
                Intent intent = new Intent(UC4.this, UC1.class);
                startActivity(intent);
            }
        });

        bn2.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //跳转到UC1
                Intent intent = new Intent(UC4.this, UC2.class);
                startActivity(intent);
            }
        });

        bn3.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //跳转到UC1
                Intent intent = new Intent(UC4.this, UC3.class);
                startActivity(intent);
            }
        });

        bn4.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //跳转到UC1
                Intent intent = new Intent(UC4.this, UC5.class);
                startActivity(intent);
            }
        });

        bnReturn.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //跳转到UC1
                Intent intent = new Intent(UC4.this, MainActivity.class);
                startActivity(intent);
            }
        });

    }
}
